Class ApplicationCommandsSchema
Defined in ApplicationCommandsSchema.ts
Constructor
constructor(options: CommandDatainterface CommandDatautils/CommandData[])
Creates a new ApplicationCommandSchema.
· options - ApplicationCommandSchema options
Example
const { ApplicationCommandSchema } = require() const commandsSchema = new ApplicationCommandSchema([ { name: 'play', implemented: true, description: 'Some description', options: { name: 'query', description: 'The song title you want to play' } } ]);
Properties
Methods
extract(): DJSApplicationCommandsSchemainterface DJSApplicationCommandsSchemautils/DJSApplicationCommandsSchema[] | [][src]
Extracts slash commands formatted for DJS.
Returns
undefinedExample
await rest.put(Routes.applicationGuildCommands('clientID', 'guildID'), { body: commandsSchema.extract() });